package com.qingfeng.client.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

/**
 * @author zhangyuefei
 * @version 1.0
 * @date 2020/1/6 10:16 上午
 */
@ApiModel(value = "com.qingfeng.client.bean.Goods")
@Data
@TableName(value = "goods")
public class Goods {
    /**
     * 具体商品id
     */
    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value = "具体商品id")
    private Long id;

    /**
     * 商品共性id
     */
    @TableField(value = "goods_common_id")
    @ApiModelProperty(value = "商品共性id")
    private Long goodsCommonId;

    /**
     * 采购价格
     */
    @TableField(value = "procurement_price")
    @ApiModelProperty(value = "采购价格")
    private Integer procurementPrice;

    /**
     * 商品标价
     */
    @TableField(value = "price")
    @ApiModelProperty(value = "商品标价")
    private Integer price;

    /**
     * 总库存
     */
    @TableField(value = "size")
    @ApiModelProperty(value = "总库存")
    private Integer size;

    /**
     * 已销售数量
     */
    @TableField(value = "sell_size")
    @ApiModelProperty(value = "已销售数量")
    private Integer sellSize;

    /**
     * 在销售的库存
     */
    @TableField(value = "can_sell_size")
    @ApiModelProperty(value = "在销售的库存")
    private Integer canSellSize;

    /**
     * 商品编码
     */
    @TableField(value = "goods_code")
    @ApiModelProperty(value = "商品编码")
    private String goodsCode;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    @ApiModelProperty(value = "创建时间")
    private Integer createTime;

    /**
     * 更改时间
     */
    @TableField(value = "update_time")
    @ApiModelProperty(value = "更改时间")
    private Integer updateTime;

    /**
     * 商品属性的状态
     */
    @TableField(value = "state")
    @ApiModelProperty(value = "商品属性的状态")
    private Integer state;

    /**
     * 单品重量
     */
    @TableField(value = "weight")
    @ApiModelProperty(value = "单品重量")
    private Integer weight;

    @TableField(exist = false)
    private List<Goods2attrs> goods2attrsBeans;

}
